Skip to content

More specific Callable type annotations in mobject_update_utils#4728

Merged
chopan050 merged 3 commits into
ManimCommunity:mainfrom
treszkai:mobject_update_annotations
Jun 3, 2026
Merged

More specific Callable type annotations in mobject_update_utils#4728
chopan050 merged 3 commits into
ManimCommunity:mainfrom
treszkai:mobject_update_annotations

Conversation

@treszkai

Copy link
Copy Markdown
Contributor

Overview: What does this pull request change?

Better type annotations for Mobject updaters for better type checking in the IDE.

Motivation and Explanation: Why and how do your changes improve the library?

Previously, type checking thought always_redraw returns a Mobject, and ignored the return type of the passed callable (artificially simple example):

image

Links to added or changed documentation pages

Further Information and Comments

Reviewer Checklist

  • The PR title is descriptive enough for the changelog, and the PR is labeled correctly
  • If applicable: newly added non-private functions and classes have a docstring including a short summary and a PARAMETERS section
  • If applicable: newly added functions and classes are tested

@treszkai treszkai force-pushed the mobject_update_annotations branch from 3d26957 to ce1df00 Compare May 20, 2026 10:26

@chopan050 chopan050 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thanks for this!

@chopan050 chopan050 enabled auto-merge (squash) June 3, 2026 16:54
@chopan050 chopan050 merged commit 33424fe into ManimCommunity:main Jun 3, 2026
14 of 15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants